<div class="art-Post">
    <div class="art-Post-tl"></div>
    <div class="art-Post-tr"></div>
    <div class="art-Post-bl"></div>
    <div class="art-Post-br"></div>
    <div class="art-Post-tc"></div>
    <div class="art-Post-bc"></div>
    <div class="art-Post-cl"></div>
    <div class="art-Post-cr"></div>
    <div class="art-Post-cc"></div>
    <div class="art-Post-body">
<div class="art-Post-inner art-article">
                <h2 class="art-PostHeader">
                    Giỏ hàng của bạn
                </h2>
                <div class="art-PostContent gio_hang">
                <?php 
                if(count($this->cart)==0){
                    echo '<h2 align="center">Trong giỏ hàng hiện chưa có sản phẩm. Vui lòng tiếp tục mua hàng.</h2>';
                }
                else{?>
                <form action="<?php $this->url(array('module'=>'front', 'controller'=>'Shopping', 'action'=>'update')) ?>" method="post">
                    <table>
                        <tr align="center" style="background-color: #EEEEEE; border: 1px solid #E2E2E2 !important;">
                            <th width="20">STT</th>
                            <th width="100">Tên</th>
                            <th width="70">Số lượng</th>
                            <th width="100">Đơn Giá</th>
                            <th width="100">Thành Tiền</th>
                            <th width="50px">Tác Vụ</th>
                        </tr>
                        <?php
                            $i = 0;
                            $tong_tien=0;
                            //$yourCart = new Zend_Session_Namespace('cart');
                            foreach($this->cart as $k=>$cart){
                                $i++;
                                $tong_tien+=$cart['thanh_tien'];
                        ?>
                        <tr style="text-align: center; background-color: #FFFFFF !important;" align="center">
                            <td style="text-align: center;" width="50"><?php echo $i ?></td>
                            <td width="100"><?php echo $cart['ten'] ?></td>
                            <td width="70" style="text-align: center !important;"><input name="txt_<?php $k?>" id="txt" value="<?php echo $cart['so_luong']?>" type="text" style="width: 40px"></td>
                            <td style="text-align: center !important;"><?php echo number_format($cart['don_gia'],-3) ?> VND</td>
                            <td style="text-align: center !important;"><?php echo number_format($cart['thanh_tien'],-3) ?> VND</td>
                            <td><a href="<?php echo $this->url(array('controller'=>'Shopping', 'action'=>'delete', 'ma'=>$k))?>"><img title="Xóa sản phẩm ra khõi giỏ hàng" src="<?php echo $this->baseUrl();?> /public/images/b_drop.png"/></a></td>
                        </tr>
                        <?php
                            }
                        ?>
                        <tr>
                            <td colspan="3" style="text-align: center !important;">Tổng cộng</td>
                            <td colspan="3" style="text-align: center !important;"><?php echo number_format($tong_tien,-3)?> VND</td>
                        </tr>
                        <tr>
                            <td colspan="7" style="text-align: center !important;">
                                <a href="<?php echo $this->url(array('module'=>'front', 'controller'=>'index',
                                                                                                        'action'=>'index'))?>">
                                    <span class="art-button-wrapper">
                                        <span class="l"> </span>
                                        <span class="r"> </span>
                                        <input style="width: 100" type="button" name="Submit" class="art-button" value="Tiếp tục mua hàng" />
                                    </span>
                                </a>
                                <a href="<?php echo $this->url(array('controller'=>'shopping', 'action'=>'update'))?>">
                                <span class="art-button-wrapper">
                                    <span class="l"> </span>
                                    <span class="r"> </span>
                                    <input type="button" name="Submit" class="art-button" value="Cập Nhật" />
                                </span>
                                </a>
                                <a>
                                <span class="art-button-wrapper">
                                    <span class="l"> </span>
                                    <span class="r"> </span>
                                    <input type="button" name="button" class="art-button" value="Thanh Toán" />
                                </span>
                                </a>
                            </td>
                        </tr>
                    <?php } ?>
                    </table>
                </form>
                </div>

                <div class="cleared"></div>
                </div>


        <div class="cleared"></div>
    </div>
</div>